﻿@model IEnumerable<KhuyenMaiVang.DAL.Category>

@{
    ViewBag.Title = "Chuyên mục";
    Layout = "~/Areas/Admin/Views/Shared/_AdminLayout.cshtml";
}

@section heading{Danh sách chuyên mục}

<p>
    @Html.ActionLink("Thêm chuyên mục", "Create")
</p>
<table>
    <thead>
        <tr>
            <th>
                Tên
            </th>
            <th>
                Thao tác
            </th>
        </tr>
    </thead>
    <tbody>
@foreach (var item in Model) {
    <tr>
        <td>
            @Html.DisplayFor(modelItem => item.Name)
        </td>
        <td>
            @Html.ImageLink("Edit", Url.Content("~/Content/areas/admin/resources/images/icons/pencil.png"), "Sửa", new{id=item.ID})
            @Html.ImageLink("Delete", Url.Content("~/Content/areas/admin/resources/images/icons/cross.png"), "Xóa", new{id=item.ID})
        </td>
    </tr>
}
    </tbody>
</table>
